home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Windows News 2010 Summer - Disc 1
/
WN_Ete2010_CD1.iso
/
Onglet5
/
Weezo
/
Weezo setup.exe
/
{code_appDir}
/
www
/
themes
/
themePreview.php
< prev
next >
Wrap
PHP Script
|
2010-05-19
|
3KB
|
61 lines
<?php
/**
* Theme preview / test
*
* PHP version 5
*
* LICENSE: This source file is subject to version 3.0 of the PHP license
* that is available through the world-wide-web at the following URI:
* http://www.php.net/license/3_0.txt. If you did not receive a copy of
* the PHP License and are unable to obtain it through the web, please
* send a note to license@php.net so we can mail you a copy immediately.
*
* @category NA
* @package NA
* @author Nicolas Bruley / Peer 2 World <contact@weezo.net>
* @copyright 2005-2009 Nicolas Bruley / Peer 2 World
* @license http://www.php.net/license/3_0.txt PHP License 3.0
* @version CVS: $Id:$
* @link http://www.weezo.net
* @since File available since Release 1.0.0
*/
//#############################################################################################################
// If user logged-in, display both frames
//#############################################################################################################
cfInsertBasicHEAD(false);
echo '<meta title="'.cfCaption('configDefaultTheme').'">'."\n";
echo '<link rel="shortcut icon" href="favicon.ico"></head>'."\n";
if(isset($_GET['theme']) && $_GET['theme']!='noTheme') $t=$_GET['theme'];
// Get theme information for main panel position
else $t=cfActualTheme();
$themeDirectory=cfAppDocRoot()."/themes/".$t;
if(file_exists($themeDirectory.'/menu.php')) require_once($themeDirectory.'/menu.php'); else require_once('common/menu.php');
if(isset($theme['menuFrame']['position']) && in_array($theme['menuFrame']['position'],array('top','left','bottom','right')) && isset($theme['menuFrame']['size'])){
switch ($theme['menuFrame']['position']){
case 'top': echo '<frameset rows="'.$theme['menuFrame']['size'].',*" frameborder=no framespacing="0" border="0">';break;
case 'bottom': echo '<frameset rows="*,'.$theme['menuFrame']['size'].'" frameborder=no framespacing="0" border="0">';break;
case 'right': echo '<frameset cols="*,'.$theme['menuFrame']['size'].'" frameborder=no framespacing="0" border="0">';break;
case 'left': echo '<frameset cols="'.$theme['menuFrame']['size'].',*" frameborder=no framespacing="0" border="0">';break;
}
}
else {
require_once('outputFunctions.php');
outDisplayErrorPage(cfcaption('errorResourceFileIncorrect'));
}
if($theme['menuFrame']['position']=='left' || $theme['menuFrame']['position']=='top') echo '<frame src="themePreviewMenu.php?theme='.urlencode($t).'" name="menuFrame" frameborder=yes border=1 noresize scrolling="'.$theme['menuFrame']['scrolling'].'">'."\n";
echo '<frame src="themePreviewBody.php?theme='.urlencode($t).'" name="mainFrame" frameborder=no border=0 noresize scrolling="auto">';
if($theme['menuFrame']['position']=='right' || $theme['menuFrame']['position']=='bottom') echo '<frame src="themePreviewMenu.php?theme='.urlencode($t).'" name="menuFrame" frameborder=yes border=1 noresize scrolling="'.$theme['menuFrame']['scrolling'].'">'."\n";
?>
</frameset>
<HTML>